[CRE][Deployments] Fix bug in OCR config count extraction#21295
[CRE][Deployments] Fix bug in OCR config count extraction#21295
Conversation
|
👋 bolekk, thanks for creating this pull request! To help reviewers, please consider creating future PRs as drafts first. This allows you to self-review and make any final changes before notifying the team. Once you're ready, you can mark it as "Ready for review" to request feedback. Thanks! |
|
✅ No conflicts with other open PRs targeting |
3021ee1 to
3aaf4bc
Compare
|
There was a problem hiding this comment.
🔴 Test Results: Base64 Decoding Error
Affected failures:
- Workflow Run: Run CCIP integration In Memory Tests For PR / smoke/ccip/ccip_messaging_test.go:Test_CCIPMessaging_Solana2EVM_LOOPP
What Broke
The extractOCR3ConfigCount function in deployment/cre/ocr3/registry_config.go attempts to unmarshal a base64 encoded protobuf configuration directly without first decoding it, leading to an unmarshalling failure.
Proposed Fixes
Update the extractOCR3ConfigCount function to base64 decode the raw configuration before unmarshalling it as a protobuf message.
+ decodedConfig, err := base64.StdEncoding.DecodeString(string(rawConfig))
+ if err != nil {
+ return 0, fmt.Errorf("failed to base64 decode capability config: %w", err)
+ }
- if err := proto.Unmarshal(rawConfig, pbCfg); err != nil;
+ if err := proto.Unmarshal(decodedConfig, pbCfg); err != nil;Autofix Options
You can apply the proposed fixes directly to your branch. Try the following:
- Comment
/trunk stack-fix 6JAMCLGEto generate a stacked PR with the proposed fixes. - Use MCP in your IDE to fix the issue. Try
Help me fix CI failures from 6JAMCLGEto get started.




Remove unnecessary JSON conversion that was messing up the types.